Determinant: Intuition
In this section, we will introduce the concept of the determinant of a matrix. It is a scalar value that can be thought of as a geometric scaling factor. It will be helpful to first understand the determinant in the context of 2D space before we generalize it to higher dimensions.
This page will focus on the geometric intuition behind the determinant. The next page will dive into the derivation for the formula to compute determinants.
Table of Contents
Introduction
Imagine a 2D linear transformation that scales the
Notice that this matrix appears to scale the space up:
Next, consider a different linear transformation:
This matrix appears to scale the space down:
Is there a way to quantify how much a matrix scales space?
We can imagine placing a square in the space and observing how the matrix transforms it.
For example, the first transformation scales the square by a factor of
This factor,
However, we only know how the matrix scales this one unit square. What if we want to know how the matrix scales any shape in space?
- Since linear transformations preserve gridlines to be parallel and evenly spaced, any rectangle will get scaled by the same factor.
- Any shape can be approximated by a collection of rectangles.
Therefore, the determinant of a matrix represents how any shape in space is scaled by the matrix.
Below is a few examples of how different matrices scale space:
- Scale Up
- Scale Down
- Flip
- Shear
- Rotate
- Squish
Determinant:
This transformation scales space up by a factor of
Determinant:
This transformation scales space down by a factor of
Determinant:
This transformation does not scale space, but appears to "flip" it.
Determinant:
This shearing transformation, while it appears to distort space, does not scale it.
Determinant:
Similar to the shearing transformation, this rotation does not scale space.
In fact, all rotations have a determinant of
Determinant:
Notice that this transformation squishes space to a line.
This means that the square "collapses" to a line, which has no area, hence the determinant is
Negative Determinants
In the example above, we saw that the determinant of a matrix can be negative if it "flips" space.
We can tell whether a space is flipped by looking at the basis vectors.
Notice that in the normal case, the basis vectors are oriented in a counterclockwise direction such that
If this orientation is reversed, such that
Notice that now,
Determinants in 3D
Consider extending the concept of determinants to 3D space.
In 2D, the determinant of a matrix represented how any area in space was scaled. We considered a unit square to understand this scaling. In 3D, we can instead consider a unit cube to understand how any volume in space is scaled.
Below is a 3D transformation along with a unit cube:
Orientation of 3D Space
In 2D, we could tell whether space was flipped by whether
The convention for this is known as the right-hand rule.
Given three positively-oriented vectors
In 3D space, if you curl your fingers from
Positively Oriented
Negatively Oriented
Implications on Linear Transformations
Consider a linear transformation that maps everything in 2D space to a single line on that space. We have already seen that this transformation can be represented by a matrix whose columns are linearly dependent.
Since the determinant of a matrix represents how space is scaled, then if the transformation squishes space to a line, the determinant must be
It also works the other way around: if the determinant of a matrix is
Hence:
The determinant of a matrix is
Additionally, when the determinant is
We say that this transformation has a mapping that is not one-to-one (or injective) because multiple vectors get mapped to the same vector. This will be very important when we discuss the concept of invertibility of matrices.
Multiplied Determinants
When we multiply two matrices, the determinant of the product is the product of the determinants of the individual matrices.
We can formally prove this, but there's a very simple geometric intuition behind this.
Recall that multiplying two matrices is equivalent to applying two transformations in sequence, called a composite transformation. The determinant of a matrix represents how space is scaled by that matrix.
When we multiply two matrices, we are applying two transformations in sequence.
If the first transformation scales space by
Summary and Next Steps
In this section, we introduced the concept of the determinant of a matrix.
Here are the key points to remember:
- The determinant of a matrix represents how space is scaled by the matrix.
- The determinant is positive if space is not "flipped", and negative if it is.
- A space can be seen as "flipped" if the orientation of the basis vectors is reversed. In 2D, this is when
is to the left of . In 3D, this is determined by the right-hand rule. - The determinant of a matrix is
if and only if the columns of the matrix are linearly dependent.
In the next section, we will actually derive the formula to compute the determinant of a matrix.